<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<%@ include file="/WEB-INF/util_file/common.jspf"%>
<%@ include file="/WEB-INF/util_file/smartEditor.jspf"%>
<link rel="stylesheet" type="text/css" media="screen" href="/jeons/css/default.css" />
<script type="text/javascript">


$(document).ready(function(){
	
	//Smart Edito 등록
	var oEditors = [];
	nhn.husky.EZCreator.createInIFrame({
	oAppRef: oEditors,
	elPlaceHolder:"content",
	sSkinURI: "/jeons/se/SEditorSkin.html",
	fCreator: "createSEditorInIFrame"
	});  	
	
	
	//등록
	$("#BtnSubmit").click(function(){
		oEditors.getById["content"].exec("UPDATE_IR_FIELD",[]);//Smart Editors
		$("#buildre").submit();
		
	});
	
	//삭제
	$("#BtnDelete").click( function(){
		location.href='/jeons/admin/buildproduct/qna/delete?qnano='+$("#tmpqnano").val();
	});
	
	
});
</script>
<input type="text" value="${data.qnano}" id="tmpqnano"/>
<div id="default">
<div><img src="/jeons/images/titledot.gif" />상품 정보</div>
<table border="0" width="650px" height="50">
	<tr>
		<td colspan="4" bgcolor="#000000" height="1"></td>
	</tr>
	<tr>
		<th height="24" align="center">상품번호</th>
		<td colspan="3" width="400px">${data.bdno} </td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
		<th height="24" align="center">상품이름</th>
		<td colspan="3">${data.gooods_names} </td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
	<tr>
		<td colspan="4" bgcolor="#000000" height="1"></td>
	</tr>
</table>

<br>
<div><img src="/jeons/images/titledot.gif" />고객의 글</div>
<table border="0" width="650px" height="50">
	<tr>
		<td colspan="4" bgcolor="#000000" height="1"></td>
	</tr>
	<tr>
		<th height="24" align="center">제목</th>
		<td colspan="3" width="400px">${data.title} </td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
		<th height="24" align="center">유저아이디</th>
		<td colspan="3">${data.u_id}</td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
		<th colspan="4" height="4" align="center">내용</th>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1">
			${data.content}
		</td>
	</tr>
	<tr>
	<tr>
		<td colspan="4" bgcolor="#000000" height="1"></td>
	</tr>
</table> 
<br>
<div><img src="/jeons/images/titledot.gif" />답변</div>
<form:form commandName="buildre" id="buildre" method="post">
<form:input path="qnano" value="${data.qnano}"/>
<form:input path="bdno" value="${data.bdno}"/>
<form:input path="bdtype" value="${data.bdtype}"/>
<form:input path="u_id" value="${data.u_id}"/>
<table border="0" width="650px" height="50">
	<tr>
		<td colspan="4" bgcolor="#000000" height="1"></td>
	</tr>
	<tr>
		<th height="24" align="center" colspan="4">답변글</th>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#ffffff" height="1">
			<form:textarea path="content" name="content" cols="75" rows="20" cssStyle="overflow-x:hidden"></form:textarea>
		</td>
	</tr>
		<td colspan="4" bgcolor="#ffffff" height="1"></td>
	</tr>
	<tr>
		<td colspan="4" bgcolor="#000000" height="1"></td>
	</tr>
</table>
<div align="right">
	<button type="button" id="BtnSubmit">확인</button>
	<button type="button" id="BtnDelete">삭제</button>
	<a href="/jeons/admin/buildproduct/qna/"><button type="button">리스트</button></a>
</div>
</form:form>
</div>
